﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Statistics_MemberQuantity.aspx.cs" Inherits="Youz.CreditRepay.Manage.Statistics.Statistics_MemberQuantity" %>

<div class="row">
    <div class="col-lg-12">
        <div class="panel panel-default">
            <div class="panel-heading">
                <h2><i class="fa fa-align-justify"></i><span style="font-size: 16px; padding-right: 15px;">会员数量统计</span></h2>
            </div>
            <div class="panel-body">

                <form class="form-horizontal">
                    <div class="row">
                        <div class="col-md-12">
                            <div class="form-group" style="text-align: right">
                                会员总数： <%:new Youz.CreditRepay.BLL.Member_InfoBLL().SumCount() %>
                            </div>
                        </div>
                    </div>
                </form>

                <table class="table table-bordered table-striped " id="table">
                    <thead>
                        <tr>
                            <th>序号</th>
                            <th>代理商</th>
                            <th>会员数量</th>
                        </tr>
                    </thead>
                    <tbody>
                    </tbody>
                </table>
                <div id="pager"></div>
            </div>
        </div>
    </div>
</div>

<script type="text/template" id="templist">
    <# 
        for (var i = 0; i < rows.length; i++) {
                var item = rows[i];
    #>
        <tr>
            <td><#=item.RowIndex #></td>
            <td><#=item.AreaName #></td>
            <td><#=item.Num #></td>
        </tr>
    <#
        }
    #>
</script>
<script type="text/javascript">

    $(function () {
        initPager();
    });

    function initPager() {
        $("#pager").pagination({
            items_per_page: 15,
            prev_text: "上一页",
            next_text: "下一页",
            url: 'Member/Handlers/Member_InfoHandler.ashx?type=MemberQuantity',
            queryParams: {
                //MemberAccount: $("#MemberAccount").val()
            },
            callback: function (opts) {
                var html = parseTemplate($("#templist").html(), opts.data);
                $("#table tbody").html(html);
            }
        });
    }

</script>
